//
//  NSString+MC_Path.m
//  RetainCount
//
//  Created by liuxiang on 2017/12/4.
//  Copyright © 2017年 liuxiang. All rights reserved.
//

#import "NSString+MC_Path.h"

@implementation NSString (MC_Path)

//返回沙盒Document路径
+ (NSString *) mc_sandBoxDocumentPath {
    NSString *docPath = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0];
    return docPath;
}

//返回沙盒Cache路径
+ (NSString *) mc_sandBoxCachePath {
    NSString *cachePath = [NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES) objectAtIndex:0];
    return cachePath;
}

//返回App所在的沙盒路径
+ (NSString *) mc_getAppMainBundlePath {
    return [NSString stringWithFormat:@"%@/",[[NSBundle mainBundle] resourcePath]];
}

@end
